<?php

class Awarenesssource extends AppModel
{

    var $name = 'Awarenesssource';
    var $displayField = 'name';
    var $order = array('Awarenesssource.name' => 'ASC');
    //The Associations below have been created with all possible keys, those that are not needed can be removed
    var $hasMany = array(
        'User' => array(
            'className' => 'User',
            'foreignKey' => 'awarenesssource_id',
            'dependent' => false,
            'conditions' => '',
            'fields' => '',
            'order' => '',
            'limit' => '',
            'offset' => '',
            'exclusive' => '',
            'finderQuery' => '',
            'counterQuery' => ''
        )
    );
    var $validate = array(
        'name' => array(
            'notEmpty' => array(
                'rule' => 'notEmpty',
                'required' => true,
                'allowEmpty' => false,
                'message' => 'Please enter name'
            ),
            'alphaNumeric' => array(
                'rule' => 'alphaNumeric',
                'message' => 'Only letters and numbers are allowed for name'
            ),
            'minLength' => array(
                'rule' => array('minLength', 2),
                'message' => 'Name should be atleast 2 characters long'
            )
        ),
        'description' => array(
            'notEmpty' => array(
                'rule' => 'notEmpty',
                'required' => true,
                'allowEmpty' => false,
                'message' => 'Please enter description'
            )
        )
    );

}
?>